package com.zqq.message.service.repository

import com.zqq.baselibrary.http.RetrofitFactory
import com.zqq.baselibrary.http.rx.BaseResp
import com.zqq.message.service.api.MessageApi
import com.zqq.message.service.bean.Message
import rx.Observable
import javax.inject.Inject

/**
 * 消息数据层
 * @author zqq on 2018/8/6
 */
class MessageRepository @Inject constructor() {

    /**
     * 获取消息列表
     */
    fun getMessageList(): Observable<BaseResp<MutableList<Message>?>> {
        return RetrofitFactory.instance
                .create(MessageApi::class.java)
                .getMessageList()
    }

}